# Copyright 2019 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#     http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

# NOTE: This file is auto generated by the elixir code generator program.
# Do not edit this file manually.

defmodule GoogleApi.DataLabeling.V1beta1.Model.GoogleCloudDatalabelingV1beta1AnnotationValue do
  @moduledoc """
  Annotation value for an example.

  ## Attributes

  *   `imageBoundingPolyAnnotation` (*type:* `GoogleApi.DataLabeling.V1beta1.Model.GoogleCloudDatalabelingV1beta1ImageBoundingPolyAnnotation.t`, *default:* `nil`) - Annotation value for image bounding box, oriented bounding box and polygon cases.
  *   `imageClassificationAnnotation` (*type:* `GoogleApi.DataLabeling.V1beta1.Model.GoogleCloudDatalabelingV1beta1ImageClassificationAnnotation.t`, *default:* `nil`) - Annotation value for image classification case.
  *   `imagePolylineAnnotation` (*type:* `GoogleApi.DataLabeling.V1beta1.Model.GoogleCloudDatalabelingV1beta1ImagePolylineAnnotation.t`, *default:* `nil`) - Annotation value for image polyline cases. Polyline here is different from BoundingPoly. It is formed by line segments connected to each other but not closed form(Bounding Poly). The line segments can cross each other.
  *   `imageSegmentationAnnotation` (*type:* `GoogleApi.DataLabeling.V1beta1.Model.GoogleCloudDatalabelingV1beta1ImageSegmentationAnnotation.t`, *default:* `nil`) - Annotation value for image segmentation.
  *   `textClassificationAnnotation` (*type:* `GoogleApi.DataLabeling.V1beta1.Model.GoogleCloudDatalabelingV1beta1TextClassificationAnnotation.t`, *default:* `nil`) - Annotation value for text classification case.
  *   `textEntityExtractionAnnotation` (*type:* `GoogleApi.DataLabeling.V1beta1.Model.GoogleCloudDatalabelingV1beta1TextEntityExtractionAnnotation.t`, *default:* `nil`) - Annotation value for text entity extraction case.
  *   `videoClassificationAnnotation` (*type:* `GoogleApi.DataLabeling.V1beta1.Model.GoogleCloudDatalabelingV1beta1VideoClassificationAnnotation.t`, *default:* `nil`) - Annotation value for video classification case.
  *   `videoEventAnnotation` (*type:* `GoogleApi.DataLabeling.V1beta1.Model.GoogleCloudDatalabelingV1beta1VideoEventAnnotation.t`, *default:* `nil`) - Annotation value for video event case.
  *   `videoObjectTrackingAnnotation` (*type:* `GoogleApi.DataLabeling.V1beta1.Model.GoogleCloudDatalabelingV1beta1VideoObjectTrackingAnnotation.t`, *default:* `nil`) - Annotation value for video object detection and tracking case.
  """

  use GoogleApi.Gax.ModelBase

  @type t :: %__MODULE__{
          :imageBoundingPolyAnnotation =>
            GoogleApi.DataLabeling.V1beta1.Model.GoogleCloudDatalabelingV1beta1ImageBoundingPolyAnnotation.t()
            | nil,
          :imageClassificationAnnotation =>
            GoogleApi.DataLabeling.V1beta1.Model.GoogleCloudDatalabelingV1beta1ImageClassificationAnnotation.t()
            | nil,
          :imagePolylineAnnotation =>
            GoogleApi.DataLabeling.V1beta1.Model.GoogleCloudDatalabelingV1beta1ImagePolylineAnnotation.t()
            | nil,
          :imageSegmentationAnnotation =>
            GoogleApi.DataLabeling.V1beta1.Model.GoogleCloudDatalabelingV1beta1ImageSegmentationAnnotation.t()
            | nil,
          :textClassificationAnnotation =>
            GoogleApi.DataLabeling.V1beta1.Model.GoogleCloudDatalabelingV1beta1TextClassificationAnnotation.t()
            | nil,
          :textEntityExtractionAnnotation =>
            GoogleApi.DataLabeling.V1beta1.Model.GoogleCloudDatalabelingV1beta1TextEntityExtractionAnnotation.t()
            | nil,
          :videoClassificationAnnotation =>
            GoogleApi.DataLabeling.V1beta1.Model.GoogleCloudDatalabelingV1beta1VideoClassificationAnnotation.t()
            | nil,
          :videoEventAnnotation =>
            GoogleApi.DataLabeling.V1beta1.Model.GoogleCloudDatalabelingV1beta1VideoEventAnnotation.t()
            | nil,
          :videoObjectTrackingAnnotation =>
            GoogleApi.DataLabeling.V1beta1.Model.GoogleCloudDatalabelingV1beta1VideoObjectTrackingAnnotation.t()
            | nil
        }

  field(:imageBoundingPolyAnnotation,
    as:
      GoogleApi.DataLabeling.V1beta1.Model.GoogleCloudDatalabelingV1beta1ImageBoundingPolyAnnotation
  )

  field(:imageClassificationAnnotation,
    as:
      GoogleApi.DataLabeling.V1beta1.Model.GoogleCloudDatalabelingV1beta1ImageClassificationAnnotation
  )

  field(:imagePolylineAnnotation,
    as: GoogleApi.DataLabeling.V1beta1.Model.GoogleCloudDatalabelingV1beta1ImagePolylineAnnotation
  )

  field(:imageSegmentationAnnotation,
    as:
      GoogleApi.DataLabeling.V1beta1.Model.GoogleCloudDatalabelingV1beta1ImageSegmentationAnnotation
  )

  field(:textClassificationAnnotation,
    as:
      GoogleApi.DataLabeling.V1beta1.Model.GoogleCloudDatalabelingV1beta1TextClassificationAnnotation
  )

  field(:textEntityExtractionAnnotation,
    as:
      GoogleApi.DataLabeling.V1beta1.Model.GoogleCloudDatalabelingV1beta1TextEntityExtractionAnnotation
  )

  field(:videoClassificationAnnotation,
    as:
      GoogleApi.DataLabeling.V1beta1.Model.GoogleCloudDatalabelingV1beta1VideoClassificationAnnotation
  )

  field(:videoEventAnnotation,
    as: GoogleApi.DataLabeling.V1beta1.Model.GoogleCloudDatalabelingV1beta1VideoEventAnnotation
  )

  field(:videoObjectTrackingAnnotation,
    as:
      GoogleApi.DataLabeling.V1beta1.Model.GoogleCloudDatalabelingV1beta1VideoObjectTrackingAnnotation
  )
end

defimpl Poison.Decoder,
  for: GoogleApi.DataLabeling.V1beta1.Model.GoogleCloudDatalabelingV1beta1AnnotationValue do
  def decode(value, options) do
    GoogleApi.DataLabeling.V1beta1.Model.GoogleCloudDatalabelingV1beta1AnnotationValue.decode(
      value,
      options
    )
  end
end

defimpl Poison.Encoder,
  for: GoogleApi.DataLabeling.V1beta1.Model.GoogleCloudDatalabelingV1beta1AnnotationValue do
  def encode(value, options) do
    GoogleApi.Gax.ModelBase.encode(value, options)
  end
end
